<html>
  <head>
    <title>Vis new user request</title>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <LINK REL=StyleSheet HREF="style.css" TYPE="text/css">
    

  </head>
  <body>
      <script LANGUAGE="JavaScript" TYPE="text/JavaScript">
    function frandisplay(active)
    {
        if(active.style.display=='none')
        {
        active.style.display='block';
        }
        else
        {
        active.style.display='none';
        }

    }

    function errorchecker()
    {
    if(newuser.requestor.value=='please use search button above')
    {
        alert ('please use manager search form');
        return;
    }
    if(newuser.name.value=='')
    {
        alert ('Please enter the name of the new user');
        return;
    }

    if(newuser.startdate.value=='dd/mm/yy')
    {
        alert ('Please enter the start date');
        return;
    }
    if(newuser.site.value=='')
    {
        alert ('Please enter the company number');
        return;
    }
    if(newuser.department.value=='')
    {
        alert ('Please enter the department');
        return;
    }
     var formObj = document.getElementById("newuser");
                formObj.submit();
    }

    </script>
      <center><h3>New user request</h3>
      
<!--      <table>
         <tr><form method="Post" Action="ldapsearch.php?f=newu" ><td>Manager search Last Name : <input type=text name=lastname></td><td><INPUT type="submit" value="Search"></td></form></tr>
      </table> -->

      <form action="newuserinsert.php" method="Post" id="newuser">
      <table class="newusertable" cellpadding="5">
           <tr class="newusertabletr">
              <td class="newusertabletd">Name of manager / controller </td>
              <?php 
              if($_POST[requestor]!='')
              {
              echo '<td class="newusertabletd"><input type="text" name="requestor" value="'.$_POST[requestor].'" readonly="readonly" />';
              }
              else
              {
              echo '<td class="newusertabletd"><input type="text" name="requestor" value="please use search button above" disabled />';
              }
              ?>
           <tr class="newusertabletr">
               <td class="newusertabletd">Email updates to</td>
               <td class="newusertabletd"><input type="text" name="mailupdates" value="<?php echo $_POST[mail] ?>"</td>
           </tr>
           <tr class="newusertabletr">
               <td class="newusertabletd">Phone number</td>
               <td class="newusertabletd"><input type="text" name="phone" value="<?php echo $_POST[phone] ?>"</td>
           </tr>
           <tr><td colspan="2"><hr></tr>
                  
                  <?php

                  echo '<input type="hidden" name="email" value="'.$_POST[email].'">';
                  ?>
                 
              </td>

          </tr>
               <tr class="newusertabletr">
              <td class="newusertabletd">Name of new user </td>
              <td class="newusertabletd"><input type="text" name="name" value="" /></td>
          </tr>
          <tr class="newusertabletr">
              <td class="newusertabletd">Start Date </td>
              <td class="newusertabletd"><INPUT type="text" name="startdate" size="5" value="dd/mm/yy"></td>
          </tr>
          <tr class="newusertabletr">
              <td class="newusertabletd">Site number </td>
              <td class="newusertabletd"><input type="text" name="site" value="" size="1" /></td>
          </tr>
           <tr class="newusertabletr">
              <td class="newusertabletd">Department</td>
              <td class="newusertabletd"><input type="text" name="department" value="" /></td>
          </tr>
          <tr class="newusertabletr">
              <td class="newusertabletd">Kerridge</td>
              <td class="newusertabletd"><input type="checkbox" name="kerridge" value="yes" onclick="frandisplay(Kerridge);" /> 
                  <div id="Kerridge" style="display:none;" >
                      Copy from: <input type="text" name="Kerridge Copy From" value="" size="3" />(3 letter login)
                      <br>Point of Sale Operator
                      <br>Location 1 <input type="checkbox" name="pos1" value="yes">
                      <br>Location 8 <input type="checkbox" name="pos8" value="yes">
                  </div></td>
          </tr>
           <tr class="newusertabletr">
              <td class="newusertabletd">Outlook Email</td>
              <td class="newusertabletd"><input type="checkbox" name="outlook" value="yes" onclick="frandisplay(Outlook);" />
                  <div id="Outlook" style="display:none;">
                      <br>VNC (if office is installed) : <input type="text" name="vnc"> or Outlook Web Access <input type="checkbox" name="outlook" value="owa">
                  </div></td>
          <tr class="newusertabletr">
              <td class="newusertabletd">Mobile phone</td>
              <td class="newusertabletd"><input type="checkbox" name="mobilePhone" value="yes" /></td>
              <tr class="newusertabletr">
              <td class="newusertabletd">Desk phone</td>
              <td class="newusertabletd"><input type="checkbox" name="deskPhone" value="yes" onclick="frandisplay(Phone);" />
              <div id="Phone" style="display:none;">
                  <table>
                      <tr><td>Exclude from vis : </td><td><input type="checkbox" name="excvis" value="yes"></td></tr>
                      <tr><td>Ext : </td><td><input type="text" name="Extention"></td></tr>
                      <tr><td>Ext to appear on vis if different</td><td><input type="text" name="Extention to appear on VIS if different" value="" ></td></tr>
                      <tr><td>new phone required : </td><td>Avaya <input type="checkbox" name="avaya" value="yes">Mitel<input type="checkbox" name="mitel" value="yes">Interquates / BT <input type="checkbox" name="BT" value="yes">Walkabout<input type="checkbox" name="walkabout" value="yes"></td></tr>
                      <tr><td>new phone line required : </td><td><input type="checkbox" name="newphone" value="yes"></td></tr>
                  </table>
              </div>
              </td>
          <tr class="newusertabletr">
              <td class="newusertabletd">Internet access</td>
              <td class="newusertabletd"><input type="checkbox" name="firewall" value="yes" /></td>
           <tr class="newusertabletr">
            <td class="newusertabletd" colspan="2"><center>Please select franchises </center></td></tr>
         <tr>
             <td class="newusertabletd" colspan="2">
                     <table width="100%" cellspacing="15" style="text-align:left">
                         <tr><td>Ford<input type="checkbox" name="ford" value="yes" onclick="frandisplay(Ford);"></td>

                     <td  id="Ford" style="display:none; text-align:center">
                         
                      <table>
                          <tr><td><h2>Ford</h2>
                      <table>
                      <tr><td>Dealer code : </td><td><input type="text" name="FordDealerCode"></td></tr>
                      <tr><td>Ecat</td><td><input type="checkbox" name="ecat" value="yes"></td></tr>
                      <tr><td><b>CDS</b></td></tr>
                      <tr><td>Copy from : </td><td><input type="text" name="CDS Copy from"> or Custom <input type="checkbox" name="custom CDS setup" Value="yes" onclick="frandisplay(fordapps);"></td></tr></table>
                  <table id="fordapps" style="display:none; text-align:center" cellpadding="5">
                      <tr><td>Application</td><td></td></tr>
                      <tr><td>Afral(afral)</td><td><input type="checkbox" name="Afral" Value="yes"></td></tr>
                      <tr><td>Cupid(cupid)</td><td><input type="checkbox" name="cupid" Value="yes"></td></tr>
                      <tr><td>CVP(cvp)</td><td><input type="checkbox" name="CVP" Value="yes"></td></tr>
                      <tr><td>SalesP@rtner(ebless2)</td><td><input type="checkbox" name="SalesP@rtner" Value="yes"></td></tr>
                      <tr><td>DBP(dbp)</td><td><input type="checkbox" name="dbp" Value="yes"></td></tr>
                      <tr><td>Dealer export and logistics(dealis)</td><td><input type="checkbox" name="dsat" Value="yes"></td></tr>
                      <tr><td>dsat(dsat)</td><td><input type="checkbox" name="dsat" Value="yes"></td></tr>
                      <tr><td>Ebless(ebless)</td><td><input type="checkbox" name="ebless" Value="yes"></td></tr>
                      <tr><td>ECTS(ects)</td><td><input type="checkbox" name="ects" Value="yes"></td></tr>
                      <tr><td>esb(esb)</td><td><input type="checkbox" name="esb" Value="yes"></td></tr>
                      <tr><td>e-TIS(etis)</td><td><input type="checkbox" name="etis" Value="yes"></td></tr>
                      <tr><td>Focal Point(focalpt)</td><td><input type="checkbox" name="focalpt" Value="yes"></td></tr>
                      <tr><td>Ford Parts Management(fpm)</td><td><input type="checkbox" name="fpm" Value="yes"></td></tr>
                      <tr><td>GCR(gcr)</td><td><input type="checkbox" name="GCR" Value="yes"></td></tr>
                      <tr><td>MIT(mit)</td><td><input type="checkbox" name="MIT" Value="yes"></td></tr>
                      <tr><td>MPS(mps)</td><td><input type="checkbox" name="MPS" Value="yes"></td></tr>
                      <tr><td>Rapid(rapid)</td><td><input type="checkbox" name="rapid" Value="yes"></td></tr>
                      <tr><td>Ford Licence(flp)</td><td><input type="checkbox" name="flp" Value="yes"></td></tr>
                      <tr><td>Learning Centre(lms)</td><td><input type="checkbox" name="lms" Value="yes"></td></tr>
                      <tr><td>Ford Protect Used Warranty(eused)</td><td><input type="checkbox" name="eused" Value="yes"></td></tr>
                      <tr><td>React(react)</td><td><input type="checkbox" name="react" Value="yes"></td></tr>
                      <tr><td>Reprints(reprints)</td><td><input type="checkbox" name="reprints" Value="yes"></td></tr>
                      <tr><td>Stock exchange(rmdbii)</td><td><input type="checkbox" name="rmdbii" Value="yes"></td></tr>
                      <tr><td>Vista(vista)(requires setting up by sales admin manager)</td><td><input type="checkbox" name="Vista" Value="yes"></td></tr>
                      <tr><td>GWMS(wms)</td><td><input type="checkbox" name="wms" Value="yes"></td></tr>
                  </table></td></tr></table>
                         <hr></td></tr>
                     
                     <tr><td>Fiat / Alfa <input type="checkbox" name="fiat" value="yes" onclick="frandisplay(Fiat);" /></td>
                         <td id="Fiat" style="display:none; text-align:center"><b>There are no applications to be setup for this franchise</b><hr></td></tr>

                     <tr><td>Mazda<input type="checkbox" name="mazda" value="yes" onclick="frandisplay(Mazda);" /></td>
                         <td id="Mazda" style="display:none; text-align:left"><table width="100%"><tr><td><center><h2>Mazda</h2><center>
                  Echo <input type="checkbox" value="yes" name="echo" onclick="frandisplay(echoapps);">
                  Portal <input type="checkbox" value="yes" name="Mazda portal" onclick="frandisplay(portal);">
                  <table id="echoapps" style="display:none; text-align:center">
                      <tr><td>Site</td><td></td><td>Job role</td></tr>
                      <tr><td>Chaddlewood(646)</td><td><input type="checkbox" value="yes" name="chaddlewood echo"></td><td>System Admin</td><td><input type="checkbox" value="yes" name="sales"></td></tr>
                      <tr><td>Liskeard(711)</td><td><input type="checkbox" value="yes" name="Liskeard echo"></td><td>Finance (Mazda Credit Docs & historical use </td><td><input type="checkbox" value="yes" name="sales"></td></tr>
                      <tr><td>Truro(539)</td><td><input type="checkbox" value="yes" name="Truro echo"></td><td>Sales & Marketing</td><td><input type="checkbox" value="yes" name="sales"></td></tr>
                      <tr><td>Exeter(724)</td><td><input type="checkbox" value="yes" name="Exeter echo"></td><td>Aftersales (Parts Warranty)</td><td><input type="checkbox" value="yes" name="sales"></td></tr>
                      <tr><td></td><td></td><td>Dealer Principal</td><td><input type="checkbox" value="yes" name="sales"></td></tr>
                      <tr><td></td><td></td><td>View Financial Reports</td><td><input type="checkbox" value="yes" name="sales"></td></tr>
                      <tr><td></td><td></td><td>Place / Amend Parts Orders</td><td><input type="checkbox" value="yes" name="sales"></td></tr>
                      <tr><td></td><td></td><td>Register Vehicles - AFRL NOS</td><td><input type="checkbox" value="yes" name="sales"></td></tr>
                      <tr><td></td><td></td><td>Vehicle Checks - Experian CDC</td><td><input type="checkbox" value="yes" name="sales"></td></tr>
                  </table>
                  <table id="portal" style="display:none; text-align:center">
                      <tr><td><b>Site</b></td></tr>
                      <tr><td>Chaddlewood(646)</td><td><input type="checkbox" value="yes" name="chaddlewood Portal"></td></tr>
                      <tr><td>Liskeard(711)</td><td><input type="checkbox" value="yes" name="Liskeard Portal"></td></tr>
                      <tr><td>Truro(539)</td><td><input type="checkbox" value="yes" name="Truro Portal"></td></tr>
                      <tr><td>Exeter(724)</td><td><input type="checkbox" value="yes" name="Exeter Portal"></td></tr>
                  <tr><td>Copy from : </td><td><input type="text" name="Mazda Portal Copy from"> or Custom <input type="checkbox" name="custom Portal setup" Value="yes" onclick="frandisplay(portalapps);"></td></tr>
                  <tr><td><table id="portalapps" style="display:none; text-align:center">
                      <tr><td><b>at least one MSDR role should be ticked</b></td></tr>
                      <tr><td><table><tr><td>
                      <table>
                      <tr><td>MSDR.FinanceManager</td><td><input type="checkbox" value="yes" name="msdar.FinanceManager"></td></tr>
                      <tr><td>MSDR.Owner</td><td><input type="checkbox" value="yes" name="msdar.Owner"></td></tr>
                      <tr><td>MSDR.PartsManager</td><td><input type="checkbox" value="yes" name="msdar.PartsManager"></td></tr>
                      <tr><td>MSDR.Principal</td><td><input type="checkbox" value="yes" name="msdar.Principal"></td></tr>
                      <tr><td>MSDR.SalesManager</td><td><input type="checkbox" value="yes" name="msdar.SalesManager"></td></tr>
                      <tr><td>MSDR.SalesPerson</td><td><input type="checkbox" value="yes" name="msdar.SalesPerson"></td></tr>
                      <tr><td>MSDR.ServiceManager</td><td><input type="checkbox" value="yes" name="msdar.ServiceManager"></td></tr>
                      <tr><td>MSDR.ServiceReceptionist</td><td><input type="checkbox" value="yes" name="msdar.ServiceReceptionist"></td></tr>
                      <tr><td>MSDR.ServiceStaff</td><td><input type="checkbox" value="yes" name="msdar.ServiceStaff"></td></tr>
                      </table></td><td>
                          <table>
                              <tr><td>Checksheet Generator</td><td><input type="checkbox" value="yes" name="checksheet generator"></td></tr>
                              <tr><td>DSR</td><td><input type="checkbox" value="yes" name="dsr"></td></tr>
                              <tr><td>eCOC</td><td><input type="checkbox" value="yes" name="ecoc"></td></tr>
                              <tr><td>eExchange</td><td><input type="checkbox" value="yes" name="eExchange"></td></tr>
                              <tr><td>eMotive</td><td><input type="checkbox" value="yes" name="eMotive"></td></tr>
                              <tr><td>ePSS</td><td><input type="checkbox" value="yes" name="ePSS"></td></tr>
                              <tr><td>eTAS</td><td><input type="checkbox" value="yes" name="eTAS"></td></tr>
                              <tr><td>eWarranty</td><td><input type="checkbox" value="yes" name="eWarranty"></td></tr>
                              <tr><td>Immobilizer</td><td><input type="checkbox" value="yes" name="Immobilizer"></td></tr>
                              <tr><td>MESI</td><td><input type="checkbox" value="yes" name="MESI"></td></tr>
                              <tr><td>ServiceExcellenceTool</td><td><input type="checkbox" value="yes" name="ServiceExcellenceTool"></td></tr>
                              <tr><td>SRT</td><td><input type="checkbox" value="yes" name="SRT"></td></tr>
                              <tr><td>WebEPC3</td><td><input type="checkbox" value="yes" name="WebEPC3"></td></tr>
                          </table>
                      </td></tr></table>
                      </table></td></tr>
                  </table>
              </td></tr></table>
                             <hr></td></tr>

                     <tr><td>Subaru<input type="checkbox" name="Subaru" value="yes" onclick="frandisplay(sub);" /></td>

                         <td id="sub" style="display:none; text-align:center"><b>There are no applications to be setup for this franchise</b><hr></td></tr>

                     <tr><td>Iveco<input type="checkbox" name="iveco" value="yes" onclick="frandisplay(ive);" /></td>

                     <td id="ive" style="display:none; text-align:center"><b>There are no applications to be setup for this franchise</b><hr></td></tr>
                     <tr><td>Peugeot<input type="checkbox" name="peugeot" value="yes"  onclick="frandisplay(Peugeot);"/></td>

                         <td id="Peugeot" style="display:none; text-align:center"><table><tr><td colspan="2"><h2>Peugeot</h2>
                  <table>
                      <tr><td>Dealer code <input type="text" name="PeugeotDealerCode"></td></tr>
                      <tr><td>Copy from<input type="text" name="PeugeotCopyFrom">or Custom <input type="checkbox" name="custom Peugeot setup" Value="yes" onclick="frandisplay(peugeotapps);"></td></tr>
                      <tr><td><table id="peugeotapps" style="display:none; text-align:center">
                                   <tr><td><b>Sales</b></td></tr>
                                   <tr><td>Sales Administrator</td><td><input type="Checkbox" value="yes" name="SalesAdmin"></tr>
                                   <tr><td>Afral Administrator</td><td><input type="Checkbox" value="yes" name="AfralAdmin"></tr>
                                   <tr><td>Salesman (new)</td><td><input type="Checkbox" value="yes" name="Salesman(new)"></tr>
                                   <tr><td>Fleet Salesman</td><td><input type="Checkbox" value="yes" name="FleetSalesman"></tr>
                                   <tr><td>Salesman (used)</td><td><input type="Checkbox" value="yes" name="Salesman(used)"></tr>
                                   <tr><td>Sales Manager(new)</td><td><input type="Checkbox" value="yes" name="SalesManager(new)"></tr>
                                   <tr><td>Sales Manager(used)</td><td><input type="Checkbox" value="yes" name="SalesManager(used)"></tr>
                                   <tr><td>Business Manager</td><td><input type="Checkbox" value="yes" name="BusinessManager"></tr>
                                   <tr><td>Sales Director</td><td><input type="Checkbox" value="yes" name="SalesDirector"></tr>
                                   <tr><td><b>Service</b></td></tr>
                                   <tr><td>Warranty Administrator</td><td><input type="Checkbox" value="yes" name="Warranty Admin"></tr>
                                   <tr><td>Master technician</td><td><input type="Checkbox" value="yes" name="Master technician"></tr>
                                   <tr><td>Technician</td><td><input type="Checkbox" value="yes" name="Technician"></tr>
                                   <tr><td>Service Receptionist</td><td><input type="Checkbox" value="yes" name="Service Receptionist"></tr>
                                   <tr><td>Service Manager</td><td><input type="Checkbox" value="yes" name="Service Manager"></tr>
                                   <tr><td>Service Assistant</td><td><input type="Checkbox" value="yes" name="Service Assistant"></tr>
                                   <tr><td>Service Director</td><td><input type="Checkbox" value="yes" name="Service Director"></tr>
                                   <tr><td>Service Internet administrator</td><td><input type="Checkbox" value="yes" name="Service Internet administrator"></tr>
                                   <tr><td><b>Parts</b></td></tr>
                                   <tr><td>Parts administrator</td><td><input type="Checkbox" value="yes" name="Parts administrator"></tr>
                                   <tr><td>Parts storeman</td><td><input type="Checkbox" value="yes" name="Parts storeman"></tr>
                                   <tr><td>Parts manager</td><td><input type="Checkbox" value="yes" name="Parts manager"></tr>
                                   <tr><td>Parts counterhand</td><td><input type="Checkbox" value="yes" name="Parts counterhand"></tr>
                                   <tr><td>Accessory consultant</td><td><input type="Checkbox" value="yes" name="Accessory consultant"></tr>
                                   <tr><td>Parts Director</td><td><input type="Checkbox" value="yes" name="Parts director"></tr>
                                   <tr><td>Parts Internet administrator</td><td><input type="Checkbox" value="yes" name="Parts internet administrator"></tr>
                                   <tr><td><b>Management</b></td></tr>
                                   <tr><td>Company secretary</td><td><input type="Checkbox" value="yes" name="Company secretary"></tr>
                                   <tr><td>DP</td><td><input type="Checkbox" value="yes" name="DP"></tr>
                                   <tr><td>Cheif accountant</td><td><input type="Checkbox" value="yes" name="Cheif accountant"></tr>
                                   <tr><td>Receptionist</td><td><input type="Checkbox" value="yes" name="Receptionist"></tr>
                                   <tr><td>Marketing manager</td><td><input type="Checkbox" value="yes" name="Marketing manager"></tr>
                                   <tr><td>Stagiaire</td><td><input type="Checkbox" value="yes" name="Stagiaire"></tr>
                              </table></table></td></tr></table>
                               </td></tr>
                     
                 </table></center>
             
          
          

              
          
          
          

                  <tr><td>Other info:</td><td><textarea rows="5" name="Other info" cols="75"></textarea></td></tr>
                  </table>
              </td></tr>

     
     </table>
     <input type="button" value="Submit form" onclick="errorchecker()">
      </form>
      </center>
  </body>
</html>
